import request from '@/utils/request'
import { parseStrEmpty } from "@/utils/ruoyi";
// import { id } from 'element-plus/es/locale';

// 查询列表
export function list(data) {
  return request({
    url: '/template/page',
    method: 'post',
    data: data
  })
}
// 社保导入
export function socialImport(data) {
    return request({
      url: '/template/import',
      method: 'post',
      headers:{'Content-Type': 'multipart/form-data'},
      data: data
    })
  }


// 查询用户详细
// export function getUser(userId) {
//   return request({
//     url: '/system/user/' + parseStrEmpty(userId),
//     method: 'get'
//   })
// }

// 新增
export function save(data) {
  return request({
    url: '/pmOtherExpense/save',
    method: 'post',
    data: data
  })
}

// 修改
export function update(id,data) {
  return request({
    url: `/pmOtherExpense/update/${id}`,
    method: 'put',
    params: data
  })
}




// 删除
export function deleteOth(id) {
  return request({
    url: `/pmOtherExpense/delete/${id}`,
    method: 'delete'
  })
}



// 提交审核
export function submitAudit(id) {
  return request({
    url: `/pmOtherExpense/submitAudit/${id}`,
    method: 'put',
  })
}
// 撤回审核
export function withdrawAudit(id) {
  return request({
    url: `/pmOtherExpense/withdrawAudit/${id}`,
    method: 'put',
  })
}

// 保存授权角色
export function updateAuthRole(data) {
  return request({
    url: '/system/user/authRole',
    method: 'put',
    params: data
  })
}


